package aop_1;/**
 * Created by burns.
 *
 * @author <a href="http://www.esoon-soft.com/">burns</a>
 * @date 2020/10/20 11:50
 */

import org.aspectj.lang.annotation.*;

/**
 * @ClassName MyAspect
 * @Description TODO
 * @Author Burns
 * @DAte 2020/10/20 11:50
 * @Version 1.0
 **/
@Aspect
public class MyAspect {

    @Pointcut("execution(* aop_1.UserServiceImpl.printUser(..))")
    public void pointCut(){

    }

    @Before("pointCut()")
    public void before(){
        System.out.println("before ......");
    }

    @After("pointCut()")
    public void after(){
        System.out.println("after ......");
    }

    @AfterReturning("pointCut()")
    public void afterReturning(){
        System.out.println("afterReturning ......");
    }

    @AfterThrowing("pointCut()")
    public void afterThrowing(){
        System.out.println("afterThrowing ......");
    }

}
